<template>
	<div>
		<el-card class="box-card">
			<div class="text item">
				<div class="hoverdivClass" v-for="(value, key) in propertyList" :key="key">
					<el-form ref="form" v-if="titleList[key]" label-position="left">
						<el-form-item :label="titleList[key]">
							<el-input v-model="propertyList[key]" type="textarea"></el-input>
						</el-form-item>
					</el-form>
				</div>
			</div>
		</el-card>
	</div>
</template>
<script>
export default {
	props: {
		getData: {
			type: Function,
			default: Function
		}
	},
	data() {
		return {
			titleList: {
				accrualDatum: '计提基准',

				accrualPointTime: '计提时点',

				accrualRatio: '计提比例',

				escrowRate: '托管费率',

				escrowRateRemark: '托管费率备注',

				feeRateAlgorithm: '管理费算法',

				generalSubscription: '前端-普通申购',

				investAdvisorAchieveReward: '投资顾问业绩报酬',

				investAdvisorRate: '投资顾问费率',

				isAchieveReward: '是否提取业绩报酬',

				managementRate: '管理费率',

				managementRateRemark: '管理费率备注',

				ordinaryRedemption: '普通赎回',

				ordinarySubscription: '普通认购',

				pensionCustomers: '认购养老金客户',

				rewardExplain: '业绩报酬说明',

				salesServiceRate: '销售服务费率',

				salesServiceRateRemark: '销售服务费率备注',

				subscriptionCustomers: '前端-申购养老金客户',

				obEndSubscription: '后端-普通申购',

				bendPensionS: '后端-申购养老金客户',
				custodyFeeAlgorithm: '托管费算法',
				salesServiceFeeAlgorithm: '销售服务费算法'
			},
			propertyList: {
				accrualDatum: '',

				accrualPointTime: '',

				accrualRatio: '',

				escrowRate: '',

				escrowRateRemark: '',

				feeRateAlgorithm: '',

				generalSubscription: '',

				investAdvisorAchieveReward: '',

				investAdvisorRate: '',

				isAchieveReward: '',

				managementRate: '',

				managementRateRemark: '',

				ordinaryRedemption: '',

				ordinarySubscription: '',

				pensionCustomers: '',

				rewardExplain: '',

				salesServiceRate: '',

				salesServiceRateRemark: '',

				subscriptionCustomers: '',

				obEndSubscription: '',

				bendPensionS: '',
				custodyFeeAlgorithm: '',
				salesServiceFeeAlgorithm: ''
			}
		}
	},
	methods: {
		saveSetings() {
			return this.propertyList
		},
		edit(data) {
			const obj = JSON.parse(JSON.stringify(data))
			this.propertyList = { ...this.propertyList, ...obj }
			for (const i in this.propertyList) {
				if (!this.propertyList[i]) {
					this.propertyList[i] = ''
				}
			}
		}
	}
}
</script>
<style lang="scss" scoped >
</style>
